#include<bits/stdc++.h>
using namespace std;

string add(string a, string b) {
	reverse(a.begin(), a.end());
	reverse(b.begin(), b.end());

	int len = max(a.size(), b.size()) + 2;

	vector<int> x(len), y(len);
	for (int i = 0; i < a.size(); i++) {
		x[i] = a[i] - '0';
	}
	for (int i = 0; i < b.size(); i++) {
		y[i] = b[i] - '0';
	}

	int t = 0, r = 0;
	string s = "";
	for (int i = 0; i < len; i++) {
		r = x[i] + y[i] + t;
		t = r / 10;
		r = r % 10;
		//		cout<<i<<" : "<<r<<endl;
		s += to_string(r);
	}
	if (t)
		s += "1";
	reverse(s.begin(), s.end());
	return s;
}

int main() {
	string s1, s2;
	cin >> s1 >> s2;
	string s = add(s1, s2);
	int idx;
	for (idx = 0; s[idx] == '0'; idx++);
	string t(s, idx);
	cout << t;
	return 0;
}
